package com.zzy.springboottest.controller;

import com.zzy.springboottest.beans.Server;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author zhouzhenyuan
 */
@RestController
public class MyController {
    
    @Autowired
    private Server server;

    @GetMapping("/")
    public String test() {
        return server.getIp()+" "+server.getName();
    }

}
